package com.neural.activation;

public class SigmoidActivation extends Activation {

	private final double a;
	private final double b;
	private final double c;
	
	public SigmoidActivation() {
		this(1.0, 1.0, 1.0);
	}
	
	public SigmoidActivation(double a, double b, double c) {
		super("Sigmoid");
		this.a = a;
		this.b = b;
		this.c = c;
	}

	@Override
	public double getValueFor(double x) {
		return a/(1.0 + b*Math.exp(-c*x));
	}

	@Override
	public double derivative(double x) {
		return (1.0-x)*x;
	}
}
